Skip to content
This repository was archived by the owner on Sep 15, 2025. It is now read-only.

Conversation

@kean
Copy link
Contributor

@kean kean commented Feb 3, 2025

Description

Fixes #

ℹ Please replace the above with a link to the issue this pull request addresses, as well as a summary of the implementation details.

Testing Details

ℹ Please replace this with a clear and concise description of the steps required to validate this pull request.


  • Please check here if your pull request includes additional test coverage.
  • I have considered if this change warrants release notes and have added them to the appropriate section in the CHANGELOG.md if necessary.

@kean kean force-pushed the fix/crash-on-invalidate branch 2 times, most recently from b187132 to df614dc Compare February 3, 2025 17:50
@kean kean force-pushed the fix/crash-on-invalidate branch from df614dc to fede7bd Compare February 3, 2025 17:57
@kean kean changed the base branch from trunk to wpios-edition February 3, 2025 18:09
@dangermattic
Copy link
Collaborator

1 Warning
⚠️ Package.swift was changed without updating its corresponding Package.resolved. Please resolve the Swift packages in Xcode.

Generated by 🚫 Danger

@kean kean force-pushed the fix/crash-on-invalidate branch from a8c0029 to fede7bd Compare February 3, 2025 19:19
@kean kean changed the title Fix/crash on invalidate Fix crash when starting a request on an invalidated session Feb 3, 2025

private var useEphemeralSession: Bool

private var isInvalidated = false
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think about changing those URLSession properties to Optional instead and assigning them to nil in the invalidateAndCancelTasks function?

success: @escaping SuccessResponseBlock,
failure: @escaping FailureReponseBlock) -> Progress? {
let progress = Progress.discreteProgress(totalUnitCount: 100)
print("GET:", Thread.callStackSymbols)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the print statements before merging.

@kean
Copy link
Contributor Author

kean commented Jun 18, 2025

Closing – was fixed in a simpler way in the app.

@kean kean closed this Jun 18, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants